package com.jie.langlangmall.service;

import com.jie.langlangmall.dto.SmsFlashPromotionProduct;
import com.jie.langlangmall.model.SmsFlashPromotionProductRelation;

import java.util.List;

/**
 * @Author Jie
 * @Date 2024/11/26
 * @Email 3217998214@qq.com
 * @Description 限时购商品关联管理
 */
public interface SmsFlashPromotionProductRelationService {

    /**
     * 商品数量
     *
     * @param flashPromotionId
     * @param flashPromotionSessionId
     * @return
     */
    long getCount(Long flashPromotionId, Long flashPromotionSessionId);

    /**
     * 添加
     *
     * @param relationList
     */
    void create(List<SmsFlashPromotionProductRelation> relationList);

    /**
     * 更新
     *
     * @param id
     * @param relation
     */
    void update(Long id, SmsFlashPromotionProductRelation relation);

    void delete(Long id);

    SmsFlashPromotionProductRelation getItem(Long id);

    List<SmsFlashPromotionProduct> list(Long flashPromotionId, Long flashPromotionSessionId, Integer pageSize, Integer pageNum);
}
